<?php 
class CpnewsletterController extends Core_Controller_Action 
{
	public function init() {
		
	}
	
	public function indexAction() {
		$this->view->status = $this->_request->getParam( 'status' );
		
		if( $this->_request->isPost() ) {
		
			$Nq = new NewsletterQueue();

			$post = $this->_request->getPost();
			$Nq->title = $post['title'];
			$Nq->text = $post['text'];
			
			$Nq->save();
			
			$this->_redirect( 'cpnewsletter/index/status/1' );
		}
	}
}

?>